#ifndef _SET_H_
#define _SET_H_
#include "../c_lib/uthash/uthash.h"
#include "../headers/pyminer_boost.h"

struct pm_int_set
{
    struct my_struct *data;
};

struct pm_int_set_iterator
{
    int64_t ended;
    int64_t started;
    struct my_struct * current;
};


struct my_struct
{
    int ikey; /* key */
    char value[10];

    UT_hash_handle hh; /* makes this structure hashable */
};

struct pm_int_set *pm_intset_create();
EXPORT void intset_init_cache();
EXPORT void pm_intset_add(struct pm_int_set *int_set, int mykey);
EXPORT int64_t pm_intset_has(struct pm_int_set *int_set, int mykey);
EXPORT void pm_intset_show(struct pm_int_set *int_set);
EXPORT void pm_intset_remove(struct pm_int_set *int_set, int64_t user_id);
EXPORT void pm_intset_free(struct pm_int_set *int_set);
EXPORT int64_t* pm_intset_to_buffer(struct pm_int_set *int_set);

#endif